cmake_minimum_required(VERSION 3.10)

set(projectName executor)

project(${projectName})

set(CMAKE_CXX_STANDARD 11)
set(CMAKE_CXX_STANDARD_REQUIRED True)

if(ENABLE_COVERAGE)
  message(STATUS "Use gcov for code coverage test")
  set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fprofile-arcs -ftest-coverage")
  set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fprofile-arcs -ftest-coverage")
endif()

include_directories(${PROJECT_SOURCE_DIR}/inc)

aux_source_directory(src DIR_SRC)

add_library(${projectName} SHARED ${DIR_SRC})

set(LIBRARY_OUTPUT_PATH ${PROJECT_SOURCE_DIR}/../../output/lib) # 设置库文件的输出目录
